package Animal_And_Interface;

public class Dog extends Animal implements IRunning, ISwimming{
    public int age;
    public Dog(String name){
        super(name);
    }

    @Override
    public void eatFood(){
        System.out.println(this.name + "正在吃狗粮！");
    }
    @Override
    public void run(){
        System.out.println(this.name + "正在用狗腿跑！");
    }
    public void bark(){
        System.out.println(this.name + "正在汪汪叫！");
    }

    @Override
    public void swim() {
        System.out.println(this.name + "正在狗刨！");
    }
}